export {}

function Window(){
  //
}

Window.prototype.hello = function(){
  console.log('hello')
}

Window.getInstance = (function(){
  let window: Window
  return function(){
    if(!window){
      window = new (Window as any)()
    }
    return window
  }
})()

const w1 = Window.getInstance()
const w2 = Window.getInstance()
console.log(w1 === w2)

